import request from '/@/utils/request';

export function useMenuApi() {
	return {
		index: (params) => {
			return request({
				url: '/auth/menu/index',
				method: 'get',
				params
			});
		},
		add: (data) => {
			return request({
				url: '/auth/menu/add',
				method: 'post',
				data
			});
		},
		edit: (data) => {
			return request({
				url: '/auth/menu/edit',
				method: 'post',
				data
			});
		},
		del: (data) => {
			return request({
				url: '/auth/menu/del',
				method: 'post',
				data
			});
		},
	};
}